package com.atguigu.boot.admin;

import com.atguigu.boot.admin.servlet.MyRegisterConfig;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.data.redis.RedisAutoConfiguration;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.web.servlet.DispatcherServlet;

//简化mybatis的mapper接口不用标注@Mapper注解,批量扫描
@MapperScan(value = "com.atguigu.boot.admin.mapper")
@ServletComponentScan(basePackages = "com.atguigu.boot.admin")
@SpringBootApplication(exclude = RedisAutoConfiguration.class)
public class Boot05WebAdminApplication {

    public static void main(String[] args) {
        ConfigurableApplicationContext context = SpringApplication.run(Boot05WebAdminApplication.class, args);
        System.out.println(context.getBean(DispatcherServlet.class));
        System.out.println(context.getBean(MyRegisterConfig.class));
    }

}
